//
//  AnoleAppManager.h
//  AnoleSDK
//
//  Created by mac on 2022/10/13.
//

//综合管理类，管理变色龙小程序的更新与存储

#import <Foundation/Foundation.h>
#import "AnoleAppInfo.h"
#import <UIKit/UIKit.h>


typedef void (^AnoleErrorAppInfoCallBack)(NSError * _Nullable error,AnoleAppInfo * _Nullable info);


NS_ASSUME_NONNULL_BEGIN

@interface AnoleAppManager : NSObject

+(AnoleAppManager *)sharedManager;

//通过appID打开一个App
-(void) openAppWithAppID:(NSString *)appID parentViewController:(UIViewController *)parentViewController compliton:(AnoleErrorAppInfoCallBack)compliton;

//获取本地存储的的小程序信息
-(void) localAppInfoWithAppID:(NSString *)appID compliton:(AnoleErrorAppInfoCallBack)compliton;

//更新本地小程序，通过检查
-(void) checkUpdateAppWithAppInfo:(AnoleAppInfo *)appInfo compliton:(AnoleErrorAppInfoCallBack _Nullable)compliton;


@end

NS_ASSUME_NONNULL_END
